﻿using System;
using Dropit.Extension.Core;
using SocialPack.Composer.Extensions;

namespace SocialPack.Composer.modules.SocialPack.Composer.Functions.Google
{
    public partial class PlusOneButton : BaseContentFunction
    {
        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            if (ContentFunctionData.IsValue("Language"))
            {
                this.PlusOneButtonControl.Language = ContentFunctionData.Property["Language"].ToString();
            }

            if (ContentFunctionData.IsValue("Width"))
            {
                this.PlusOneButtonControl.Width = Convert.ToInt32(ContentFunctionData.Property["Width"]);
            }
        }
    }
}